Skip to content

Port upstream RNNT loss with pytorch Stable ABI#10

Closed
amd-sriram wants to merge 1 commit intomainfrom
rocm_rnnt_loss
Closed

Port upstream RNNT loss with pytorch Stable ABI#10
amd-sriram wants to merge 1 commit intomainfrom
rocm_rnnt_loss

Conversation

@amd-sriram
Copy link

@amd-sriram amd-sriram commented Nov 7, 2025

Motivation

RNNT loss is currently not implemented in rocm/audio. The aim of this PR is to port it into ROCm.

Technical Details

  • Hipify code using hipify torch
  • Add #include <torch/csrc/stable/tensor.h> to torchaudio/csrc/rnnt/gpu/compute.cu to avoid the following error:
ld.lld: error: undefined hidden symbol: torch::stable::Tensor::scalar_type() const  
>>> referenced by compute.hip  
>>>               src/libtorchaudio/CMakeFiles/libtorchaudio.dir/rnnt/gpu/compute.hip.o:(torchaudio::rnnt::gpu::compute(torch::stable::Tensor const&, torch::stable::Tensor const&, torch::stable::Tensor const&, torch::stable::Tensor const&, long, double, bool)) 
  • Include the hipified files in the source code

Test Plan

pytest test/torchaudio_unittest/functional/functional_cuda_test.py -k test_rnnt  
pytest test/torchaudio_unittest/transforms/torchscript_consistency_cuda_test.py -k test_rnnt 

Test Result

@amd-sriram amd-sriram changed the title hipify rnnt loss code, include corrected header files, add hipify pyt… Port upstream RNNT loss with pytorch Stable ABI Nov 7, 2025
@amd-sriram amd-sriram closed this Feb 21, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant